package com.myc.subject.application.convert;

import com.myc.subject.application.dto.SubjectCategoryDTO;
import com.myc.subject.application.dto.SubjectInfoDTO;
import com.myc.subject.domain.entity.SubjectCategoryBO;
import com.myc.subject.domain.entity.SubjectInfoBO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * 将BO转为 SubjectCategory的拦截器,使用mapstruct的工厂进行转换
 * */
@Mapper
public interface SubjectInfoDTOConverter {

    SubjectInfoDTOConverter INSTANCE = Mappers.getMapper(SubjectInfoDTOConverter.class);

    SubjectInfoBO convertDtoToInfoBO(SubjectInfoDTO subjectInfoDTO);

    List<SubjectInfoDTO> convertBoToInfoDto(List<SubjectInfoBO> subjectInfoBOS);

    SubjectInfoDTO convertBoToInfoDto(SubjectInfoBO subjectInfoBO);

}
